% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/shapefile_xyz.R
\name{shapefile_from_folder}
\alias{shapefile_from_folder}
\title{Read shapefile from a folder}
\usage{
shapefile_from_folder(folder = NULL, cleanit = TRUE, crs = 4269, ...)
}
\arguments{
\item{folder}{path of folder that contains the files (.shp, .shx, .dbf, and .prj)}

\item{cleanit}{set to FALSE if you want to skip validation and dropping invalid rows}

\item{crs}{passed to shapefile_from_filepaths() default is crs = 4269 or Geodetic CRS NAD83}

\item{...}{passed to \code{\link[sf:st_read]{sf::st_read()}}}
}
\value{
a shapefile object using sf::st_read()
}
\description{
Read shapefile from a folder
}
\examples{
\dontrun{
  testfolder <- system.file("testdata/shapes/Portland_neighborhoods", package = "EJAM")
  testshape <- shapefile_from_folder(testfolder)

  testpaths <- shapefile_filepaths_from_folder(testfolder)
  testshape <- shapefile_from_filepaths(testpaths)

  ## if interactive(), R user can point to right folder or select the right set of files:
  # testshape <- shapefile_from_filepaths()
  # testshape <- shapefile_from_folder()

  x <- get_blockpoints_in_shape(testshape)
  leaflet(x$polys) \%>\% addTiles() \%>\% addPolygons(color = "blue")
  DT::datatable(out$results_bysite)

  }
}
\seealso{
\code{\link[=shapefile_from_folder]{shapefile_from_folder()}}
}
